.class public abstract Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;
.super Ljava/lang/Object;
.source "AbstractMeasuringModel.java"


# instance fields
.field protected shape:Llt/noframe/gpsfarmguide/interfaces/Shape;


# direct methods
.method public constructor <init>(Llt/noframe/gpsfarmguide/interfaces/Shape;)V
    .locals 0

    .line 22
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    .line 23
    iput-object p1, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    return-void
.end method


# virtual methods
.method public addPoint(Lcom/google/android/gms/maps/model/LatLng;)V
    .locals 1

    .line 27
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0, p1}, Llt/noframe/gpsfarmguide/interfaces/Shape;->addPoint(Lcom/google/android/gms/maps/model/LatLng;)V

    .line 29
    iget-object p1, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {p1}, Llt/noframe/gpsfarmguide/interfaces/Shape;->getPoints()Ljava/util/List;

    move-result-object p1

    if-eqz p1, :cond_0

    iget-object p1, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {p1}, Llt/noframe/gpsfarmguide/interfaces/Shape;->getPoints()Ljava/util/List;

    move-result-object p1

    invoke-interface {p1}, Ljava/util/List;->size()I

    move-result p1

    const/4 v0, 0x6

    if-ne p1, v0, :cond_0

    .line 30
    invoke-static {}, Llt/noframe/gpsfarmguide/App;->getContext()Landroid/content/Context;

    move-result-object p1

    const-string v0, "manual_measuring_reached_3pts"

    invoke-static {v0, p1}, Llt/noframe/gpsfarmguide/App;->stateChanged(Ljava/lang/String;Landroid/content/Context;)V

    :cond_0
    return-void
.end method

.method public deletePoint(Lcom/google/android/gms/maps/model/Marker;)V
    .locals 1

    .line 38
    invoke-static {}, Llt/noframe/gpsfarmguide/Data;->getInstance()Llt/noframe/gpsfarmguide/Data;

    move-result-object v0

    invoke-virtual {v0}, Llt/noframe/gpsfarmguide/Data;->getSelectedMarker()Lcom/google/android/gms/maps/model/Marker;

    move-result-object v0

    if-eqz v0, :cond_0

    .line 39
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0, p1}, Llt/noframe/gpsfarmguide/interfaces/Shape;->deletePoint(Lcom/google/android/gms/maps/model/Marker;)V

    .line 40
    invoke-static {}, Llt/noframe/gpsfarmguide/Data;->getInstance()Llt/noframe/gpsfarmguide/Data;

    move-result-object p1

    const/4 v0, 0x0

    invoke-virtual {p1, v0}, Llt/noframe/gpsfarmguide/Data;->setSelectedMarker(Lcom/google/android/gms/maps/model/Marker;)V

    :cond_0
    return-void
.end method

.method public doCalculations()V
    .locals 1

    .line 74
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->doCalculations()V

    return-void
.end method

.method public draw()V
    .locals 1

    .line 66
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->draw()V

    return-void
.end method

.method public getMarkers()Ljava/util/List;
    .locals 1
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()",
            "Ljava/util/List<",
            "Lcom/google/android/gms/maps/model/Marker;",
            ">;"
        }
    .end annotation

    .line 58
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->getMarkers()Ljava/util/List;

    move-result-object v0

    return-object v0
.end method

.method public getPoints()Ljava/util/List;
    .locals 1
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()",
            "Ljava/util/List<",
            "Lcom/google/android/gms/maps/model/LatLng;",
            ">;"
        }
    .end annotation

    .line 50
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->getPoints()Ljava/util/List;

    move-result-object v0

    return-object v0
.end method

.method public getType()I
    .locals 1

    .line 102
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->getType()I

    move-result v0

    return v0
.end method

.method public getWkt()Ljava/lang/String;
    .locals 1

    .line 106
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->getWkt()Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public markMeasure()V
    .locals 1

    .line 86
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->markMeasure()V

    return-void
.end method

.method public redraw()V
    .locals 1

    .line 62
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->redraw()V

    return-void
.end method

.method public remove()V
    .locals 1

    .line 34
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->remove()V

    return-void
.end method

.method public removeMarkers()V
    .locals 1

    .line 82
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->removeMarkers()V

    return-void
.end method

.method public restoreInitialState()V
    .locals 1

    .line 98
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->restoreInitialState()V

    return-void
.end method

.method public saveState()V
    .locals 1

    .line 78
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->saveState()V

    return-void
.end method

.method public setColor(I)V
    .locals 1

    .line 70
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0, p1}, Llt/noframe/gpsfarmguide/interfaces/Shape;->setColor(I)V

    return-void
.end method

.method public setForEditing()V
    .locals 1

    .line 110
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->setForEditing()V

    return-void
.end method

.method public setPoints(Ljava/util/List;)V
    .locals 1
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Ljava/util/List<",
            "Lcom/google/android/gms/maps/model/LatLng;",
            ">;)V"
        }
    .end annotation

    .line 54
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0, p1}, Llt/noframe/gpsfarmguide/interfaces/Shape;->setPoints(Ljava/util/List;)V

    return-void
.end method

.method public undo()V
    .locals 1

    .line 45
    invoke-static {}, Llt/noframe/gpsfarmguide/utils/Drawing;->deselectMarker()V

    .line 46
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->undo()V

    return-void
.end method

.method public unmarkMeasure()V
    .locals 1

    .line 90
    iget-object v0, p0, Llt/noframe/gpsfarmguide/models/AbstractMeasuringModel;->shape:Llt/noframe/gpsfarmguide/interfaces/Shape;

    invoke-interface {v0}, Llt/noframe/gpsfarmguide/interfaces/Shape;->unmarkMeasure()V

    return-void
.end method
